//
//  SISSJsonRequestNetworkingManager+Registration.h
//  SISSAPP
//
//  Created by 优房网 on 2017/4/21.
//  Copyright © 2017年 优房网. All rights reserved.
//

#import "SISSJsonRequestNetworkingManager.h"
#import "SISSHouseResourceModel.h"
#import "SISSPassengerResourceModel.h"
#import "SISSRentOutModel.h"
#import "SISSTenantModel.h"
#import "SISSBuildingNumberModel.h"
#import "SISSRoomFloorModel.h"
#import "SISSHouseDetailsInfoModel.h"
#import "SISSHouseEstateHomePageInfoModel.h"
#import "SISSKPIDetailModel.h"

@interface SISSJsonRequestNetworkingManager (Registration)


/**
 3.1.1.1 模糊搜索小区 GET请求
 
 @param keyword 小区名
 @param successBlock 成功的回调
 @param failedBlock 失败的回调
 */
- (void)fuzzySearchHouseResourceCommunityWithKeyword:(NSString *)keyword successBlock:(void(^)(id responseObject))successBlock failed:(void(^)(NSError *error))failedBlock;

/**
 3.1.1.2 根据小区获取楼栋列表 GET请求
 
 @param communityName 小区名
 @param successBlock 成功的回调
 @param failedBlock 失败的回调
 */
- (void)requestBuildingResourceWithCommunityName:(NSString *)communityName successBlock:(void(^)(NSArray<SISSBuildingNumberModel *> *buildingArr))successBlock failed:(void(^)(NSError *error))failedBlock;

/**
 3.1.1.3 根据楼栋获取房号列表 GET请求
 
 @param buildingId 栋id
 @param successBlock 成功的回调
 @param failedBlock 失败的回调
 */
- (void)requestHouseRoomNumberWithBuilding:(NSString *)buildingId successBlock:(void(^)(NSArray<SISSRoomFloorModel *> *roomNumberArr))successBlock failed:(void(^)(NSError *error))failedBlock;

/**
 3.1.1.4 根据房源获取推荐售价 GET请求
 
 @param communityName 小区名
 @param successBlock 成功的回调
 @param failedBlock 失败的回调
 */
- (void)requestHouseEstateHomePageInfoWithCommunityName:(NSString *)communityName successBlock:(void(^)(SISSHouseEstateHomePageInfoModel *houseEstateHomePageInfoModel))successBlock failed:(void(^)(NSError *error))failedBlock;

/**
  3.1.1.5 获取房源信息 GET请求
 
 @param landId 房源编号
 @param successBlock 成功的回调
 @param failedBlock 失败的回调
 */
- (void)requestHouseDetailsInfoWithLandId:(NSString *)landId successBlock:(void(^)(SISSHouseDetailsInfoModel *houseDetailsInfo))successBlock failed:(void(^)(NSError *error))failedBlock;

/**
 3.1.1 房源登记

 @param houseModel 房源模型
 @param successBlock 成功的回调
 @param failedBlock 失败的回调
 */
- (void)enrollHouseResourceWithHouseModel:(SISSHouseResourceModel *)houseModel successBlock:(void(^)(id responseObject))successBlock failed:(void(^)(NSError *error))failedBlock;

/**
 3.1.2 客源登记
 
 @param passengerModel 客源模型
 @param successBlock 成功的回调
 @param failedBlock 失败的回调
 */
- (void)enrollPassengerResourceWithHouseModel:(SISSPassengerResourceModel *)passengerModel successBlock:(void(^)(id responseObject))successBlock failed:(void(^)(NSError *error))failedBlock;

/**
 3.2.1 筛选已获得委托未发布合作的房源
 
 @param parameters 筛选参数
 @param successBlock 成功模型数组的回调
 @param failedBlock 失败的回调
 */
- (void)requestHouseCooperationWithparameters:(NSDictionary *)parameters success:(void(^)(NSArray<SISSHouseResourceModel *> * houseResources))successBlock failed:(void(^)(NSError *error))failedBlock;

/**
 3.2.2 筛选已获得委托未发布合作的客源

 @param parameters 筛选参数
 @param successBlock 成功模型数组的回调
 @param failedBlock 失败的回调
 */
- (void)requestPassengerCooperationWithparameters:(NSDictionary *)parameters success:(void(^)(NSArray<SISSPassengerResourceModel *> * passengerResources))successBlock failed:(void(^)(NSError *error))failedBlock;

/**
 6.1.1 修改线下房源
 
 @param houseModel 房源模型
 @param successBlock 成功的回调
 @param failedBlock 失败的回调
 */
- (void)updateHouseResourceWithHouseModel:(SISSHouseResourceModel *)houseModel successBlock:(void(^)(id responseObject))successBlock failed:(void(^)(NSError *error))failedBlock;

/**
 6.1.2 更新线下客源
 
 @param passengerModel 客源模型
 @param successBlock 成功的回调
 @param failedBlock 失败的回调
 */
- (void)updatePassengerResourceWithPassengerModel:(SISSPassengerResourceModel *)passengerModel successBlock:(void(^)(id responseObject))successBlock failed:(void(^)(NSError *error))failedBlock;

#pragma mark - 2.0
/**
 3.1.3 插入线下出租信息
 
 @param rentOutModel 出租模型
 @param successBlock 成功的回调
 @param failedBlock 失败的回调
 */
- (void)insertLeaseResourceOfflineWithRentOutModel:(SISSRentOutModel *)rentOutModel imagesArray:(NSArray *)imagesArray successBlock:(void(^)(id responseObject))successBlock failed:(void(^)(NSError *error))failedBlock;

/**
 3.1.4 插入线下租客信息
 
 @param tenantModel 租客模型
 @param successBlock 成功的回调
 @param failedBlock 失败的回调
 */
- (void)insertTenantResourceOfflineWithTenantModel:(SISSTenantModel *)tenantModel successBlock:(void(^)(id responseObject))successBlock failed:(void(^)(NSError *error))failedBlock;

/**
 6.1.3 修改线下出租
 
 @param rentOutModel 出租模型
 @param imagesArray imagesArray
 @param successBlock 成功的回调
 @param failedBlock 失败的回调
 */
- (void)updateRentOutResourceWithRentOutModel:(SISSRentOutModel *)rentOutModel imagesArray:(NSArray *)imagesArray successBlock:(void(^)(id responseObject))successBlock failed:(void(^)(NSError *error))failedBlock;

/**
 6.1.4 更新线下租客
 
 @param tenantModel 租客模型
 @param successBlock 成功的回调
 @param failedBlock 失败的回调
 */
- (void)updateTenantResourceWithTenantModel:(SISSTenantModel *)tenantModel successBlock:(void(^)(id responseObject))successBlock failed:(void(^)(NSError *error))failedBlock;


/**
 3.4.1 经纪人业绩申报
 
 @param parameters 申报参数
 @param successBlock 成功的回调
 @param failedBlock 失败的回调
 */
- (void)insertAchievementApplyWithParameters:(NSDictionary *)parameters successBlock:(void(^)(id responseObject))successBlock failed:(void(^)(NSError *error))failedBlock;


/**
 3.4.2 获取经纪人业绩申详情 GET请求

 @param ID id
 @param successBlock 成功的回调
 @param failedBlock 失败的回调
 */
- (void)requestAchievementDetailWithID:(NSString *)ID successBlock:(void(^)(SISSKPIDetailModel *KPIDetailModel))successBlock failed:(void(^)(NSError *error))failedBlock;

/**
 3.4.3 修改经纪人业绩申报 PUT请求
 
 @param parameters 参数
 @param successBlock 成功的回调
 @param failedBlock 失败的回调
 */
- (void)updateAchievementApplyWithParameters:(NSDictionary *)parameters successBlock:(void(^)(id responseObject))successBlock failed:(void(^)(NSError *error))failedBlock;

/**
 3.4.4 删除经纪人业绩申报 DELETE请求
 
 @param ID id
 @param successBlock 成功的回调
 @param failedBlock 失败的回调
 */
- (void)deleteAchievementDetailWithID:(NSString *)ID successBlock:(void(^)(id responseObject))successBlock failed:(void(^)(NSError *error))failedBlock;

/**
 3.1.3 验证房源编码

 @param houseNum 房源编码
 @param roomNum 房号
 @param successBlock 成功的回调
 @param failedBlock 失败的回调
 */
- (void)verifyHouseNumWithHouseNum:(NSString *)houseNum roomNum:(NSString *)roomNum successBlock:(void(^)(id responseObject))successBlock failed:(void(^)(NSError *error))failedBlock;

/**
 3.5.1 模糊搜索机构 GET请求
 
 @param keyword 机构名称
 @param successBlock 成功的回调
 @param failedBlock 失败的回调
 */
- (void)fuzzySearchOrganithKeyword:(NSString *)keyword successBlock:(void(^)(id responseObject))successBlock failed:(void(^)(NSError *error))failedBlock;

/**
 3.6.1 获取给房源智能推荐的客源 GET请求

 @param ahrid ahrid
 @param successBlock 成功模型数组的回调
 @param failedBlock 失败的回调
 */
- (void)requestHouseRecommendDemandWithAhrId:(NSString *)ahrId success:(void(^)(NSArray<SISSPassengerResourceModel *> * passengerResources))successBlock failed:(void(^)(NSError *error))failedBlock;

/**
 3.6.2 获取给客源智能推荐的房源 GET请求
 
 @param abdid abdid
 @param successBlock 成功模型数组的回调
 @param failedBlock 失败的回调
 */
- (void)requestBuyerDemandRecommendHouseWithAbdId:(NSString *)abdId  success:(void(^)(NSArray<SISSHouseResourceModel *> * houseResources))successBlock failed:(void(^)(NSError *error))failedBlock;

/**
 3.6.3 获取给出租智能推荐的租客 GET请求
 
 @param alrId 出租id
 @param successBlock 成功模型数组的回调
 @param failedBlock 失败的回调
 */
- (void)requestRentOutRecommendTenantWithAlrId:(NSString *)alrId success:(void(^)(NSArray<SISSTenantModel *> *tenantResources))successBlock failed:(void(^)(NSError *error))failedBlock;


/**
 3.6.4 获取给租客智能推荐的出租 GET请求
 
 @param arrId 租客id
 @param successBlock 成功模型数组的回调
 @param failedBlock 失败的回调
 */
- (void)requestTenantRecommendRentOutWithArrId:(NSString *)arrId success:(void(^)(NSArray<SISSRentOutModel *> *rentOutResources))successBlock failed:(void(^)(NSError *error))failedBlock;


@end
